<?php
include ('m_user.php');
	  // hàm ki?m tra email
	  $email=$_GET['email'];
	  $mess=null;
            if (strlen($email) == 0) $mess="<img src='images/error.png'> Email không hợp lệ!</img> <input type=hidden id='checkEmail' value ='false'/>";
            if (preg_match("/^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,4})$/", $email)) 
			{
				if (checkEmail($email)==false)
				{
				$mess="<img src='images/ok.png'></img> <input type=hidden id='checkEmail' value ='true'/>";
				}
				else {$mess="<img src='images/error.png'></img>Email đã đăng ký <input type=hidden id='checkEmail' value ='false'/>";}
			}
			else {$mess="<img src='images/error.png'> Email không hợp lệ!</img> <input type=hidden id='checkEmail' value ='false'/>";}
            echo $mess;         

?>